<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <!-- 组件注册语法糖 -->
    <div id="app">
        <my-cpn></my-cpn>
        <my-cpn-two></my-cpn-two>
    </div>
    <script src="../js/vue.js"></script>
    <script>
        Vue.component('my-cpn',{
            template:`
            <div>我是全局语法糖注册的组件</div>
            `
        })
        const app = new Vue({
            el:'#app',
            data(){
                return {

                }
            },
            components:{
                'my-cpn-two':{
                    template:`
                    <div>我是一个语法糖注册的局部组件</div>
                    `
                }
            }
        })
    </script>
</body>
</html>